Today, many browsers are designed to disallow what is known as cross site scripting. That is, web pages are associated with domains. If a web page from a one domain attempts to communicate or execute a script on a web page from a different domain, many web browsers will disallow the communication or script execution. There are various reasons why this is done, many of which pertain to security.
Notwithstanding the concerns associated with security and which have driven, to a certain extent, the restrictions on cross site scripting, there is value that can arise by allowing communication across different domains.